home *** CD-ROM | disk | FTP | other *** search
/ Alles Voor Internet / Tout Pour Internet / alles voor internet.iso / MacInternet™ / Telnet / NCSA / tn3270 2.4d7 source / NCSA⁄BYU TCP⁄IP / hostform.h < prev    next >
Text File  |  1991-12-16  |  4KB  |  109 lines

  1. /**************************************************************************/
  2. /*  storage of machine information
  3. *      structure for a linked list of information about other machines
  4. *  that we may want to talk to.
  5. *
  6. *  Defines and structures for use in this file
  7. */
  8.  
  9.  
  10. struct machinfo {
  11.     unsigned char 
  12.         *sname,                    /* pointer to name of session */
  13.         *hname,                 /* pointer to name of that machine */
  14.         *font,                    /* font name, if we can do it */
  15.         hostip[4],                /* IP number of this machine */
  16.         gateway,                /* gateway preference, start with 1 */
  17.         nameserv,                /* nameserver preference, start with 1 */
  18.         bksp,                    /* backspace value */
  19.         halfdup,                /* half duplex required */
  20.         linemode,                /* enable line mode */            /* BYU 2.4.9 */
  21.         eightbit,                /* display as 8 bit font */        /* BYU 2.4.9 */
  22.         crmap,                    /* Strange Berkeley 4.3 CR mode needed */
  23.         ckey,                    /* int,sus,res mappings, traditional ^C,^S,^Q */
  24.         skey,
  25.         qkey,
  26.         vtwrap,                    /* flag on when need wrap mode */
  27.         vtwidth;                /* how wide screen should be for this session */
  28.     int
  29.         clearsave,                /* whether to save cleared lines */
  30.         tektype,
  31.         fsize;                    /* font size in points */
  32.     unsigned int
  33.         nfcolor[3],                /* normal foreground */
  34.         nbcolor[3],                /* normal background */
  35.         bfcolor[3],                /* blink             */
  36.         bbcolor[3],
  37.         ufcolor[3],             /* underline */
  38.         ubcolor[3];
  39.     int
  40.         port,                    /* TCP port number to access, default = 23 (telnet) */
  41.         mno,                    /* machine number for reference */
  42.         mstat,                    /* status of this machine entry */
  43.         bkscroll,                /* how many lines to save */
  44.         nlines,                    /* number of lines for VT100 screen */
  45.         retrans,                /* initial retrans timeout */
  46.         conto,                    /* time out in seconds to wait for connect */
  47.         window,                    /* window, will be checked against buffers */
  48.         maxseg,                    /* maximum receivable segment size */
  49.         mtu;                    /* maximum transfer unit MTU (out) */
  50.  
  51.     struct machinfo *next;        /* surprise, its a linked list! */
  52. };
  53.  
  54. struct machinfo *Sgethost(),*Shostlook(),*Slooknum(),*Slookip(),*Smadd();
  55.  
  56. /*
  57. *  status fields for mstat, what do we know about that machine?
  58. */
  59. #define NOIP 1                    /* we don't have IP number */
  60. #define UDPDOM 3                /* there is a UDP request pending on it */
  61. /*  The next 20 numbers are reserved for UDPDOM */
  62. #define HAVEIP 50                /* at least we have the # */
  63. #define HFILE 70                /* we have IP number from host file */
  64. #define DOM 71                    /* we have an IP number from DOMAIN */
  65. #define FROMKIP 72                /* have IP# from KIP server */
  66.  
  67. /*
  68. *   Configuration information which 
  69. *   the calling program may want to obtain from the hosts file.
  70. *   The calling program should include hostform.h and call
  71. *   Sgetconfig(cp)
  72. *     struct config *cp;
  73. *   which will copy the information to the user's data structure.
  74. */
  75. struct config {
  76.     unsigned char
  77.         netmask[4],                /* subnetting mask being used */
  78.         havemask,                /* do we have a netmask? */
  79.         irqnum,                    /* which hardware interrupt */
  80.         myipnum[4],                /* what is my IP #? */
  81.         me[32],                    /* my name description (first 30 chars) */
  82.         color[3],                /* default colors to use */
  83.         hw[10],                    /* hardware type for network */
  84.         video[10],                /* video graphics hardware available */
  85.         bios,                    /* flag, do we want to use BIOS for screen access */
  86.         tek,                    /* flag, enable tektronix graphics */
  87.         ftp,                    /* flag, enable ftp server */
  88.         rcp,                    /* flag, enable rcp server */
  89.         comkeys,                /* flag, commandkeys=yes */
  90.         *termtype,                /* terminal type specification */
  91.         *zone,                    /* AppleTalk zone for KIP NBP */
  92.         *defdom,                /* default domain */
  93.         *capture,                /* pointer to where the capture file name is */
  94.         *pass,                    /* pointer to where the password file name is */
  95.         *hpfile,                /* HP file name */
  96.         *psfile,                /* PS file name */
  97.         *tekfile;                /* tek file name */
  98. int
  99.         nstype,                    /* nameserver = 1-domain 2-IEN116  */
  100.         domto,                    /* time out for UDP domain request */
  101.         ndom,                    /* number of retries for domain requests */
  102.         timesl,                    /* time slice */
  103.         textblock,                /* text buffering block size */
  104.         address,                /* segment address */
  105.         ioaddr,                    /* I/O address */
  106.         tektype;
  107. };
  108.  
  109.